Skip to content

fix(deps): avoid incompatible FastAPI telemetry dependencies - #3053

Open
frf12 wants to merge 2 commits into
oceanbase:masterfrom
frf12:codex/fix-fastapi-otel-compat
Open

frf12 wants to merge 2 commits into
oceanbase:masterfrom
frf12:codex/fix-fastapi-otel-compat

Conversation

@frf12

@frf12 frf12 commented Dec 4, 2026

Copy link
Copy Markdown
Member

Which issue or RFC does this PR close?

No issue closed. Follow-up to the independently diagnosed cold-installation failures in #3050.

Rationale for this change

Fresh Server installations can resolve FastAPI 0.165.1 with OpenTelemetry API 1.46.0. FastAPI passes logger arguments positionally, while the new OpenTelemetry version makes them keyword-only. HTTP requests then fail with TypeError: get_logger() takes 1 positional argument but 3 positional arguments (and 1 keyword-only argument) were given.

A minimal FastAPI ASGI application, without importing PowerContext, reproduces the failure with 1.46.0 and returns HTTP 200 with 1.45.3. This explains the macOS native lifecycle failure and macOS installation failure.

What changes are included in this PR?

  • Bound the Server extra's OpenTelemetry API dependency below 1.46. Compatible SDK and optional exporter versions resolve through their existing dependency requirements.
  • Apply one shared compatibility constraint when installing historical source releases in native lifecycle and installed-release upgrade acceptance. Published source wheel URLs and hashes remain unchanged; current wheels carry the bound in package metadata.
  • Synchronize the three lockfiles' project requirement metadata. All third-party locked versions, sources and archive hashes remain unchanged.

Are there any user-facing changes?

Fresh Server installs avoid the incompatible telemetry release. No public API, schema, timeout, assertion, runner, resource or concurrency changes.

How was this change tested?

  • Built a wheel and sdist; cold-installed the current Server wheel and the exact published 1.3.0 source wheel. Both resolve FastAPI 0.165.1 with OpenTelemetry API/SDK 1.45.3.
  • Real macOS LaunchAgent lifecycle acceptance: 16 passed, 5 platform-specific skips in 243.75 seconds, including installed-release upgrade scenarios.
  • Both previously failing native installation scenarios passed: existing and bootstrap-global, exercising Server readiness, remember/search, offline reinstall and persisted data. Used the release-shaped 1.2.0 fixture required by the workflow. Bootstrap validation used a non-Conda environment matching CI; an earlier local run inherited Conda and failed before reaching the reported telemetry defect.
  • Upgrade release gate tests: 129 passed, 6 Linux-only skips.
  • Full prek checks including ty, make ci-runners-check, all three lockfile checks and git diff --check passed. Existing platform runners and shared setup remain unchanged.
  • Optional Server + OTLP dependencies resolve compatibly; actual OTLP backend export was not exercised. Hosted CI on this PR remains to be validated.

AI usage statement

Implemented and validated with OpenAI Codex.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant